1. Field of the Invention
The present invention relates to a communication apparatus and control method thereof, and more particularly to a communication apparatus that wirelessly communicates in power save mode in an adhoc network and control method thereof.
2. Description of the Related Art
In recent years, owing to the integration of devices for wireless communication, not only portable personal computers (so-called notebook PCs), but also various other devices, such as printers, personal digital assistants (PDAs), digital cameras, cellular phones, etc. have come to be equipped with wireless communication capability. In these wireless communication apparatuses, since smaller apparatuses equate to smaller capacities of battery which can be included, there is a growing need to reduce power consumption in wireless communication.
As a function for reducing power consumption in wireless LAN communication, power save mode (hereinafter also referred to as “PS model”) is defined in the IEEE802.11 standard. The basic principle of PS mode is that a wireless receiver is powered to be operated for a short period at and around the time when a beacon is expected to be transmitted, but power feeding to the wireless receiver is cut for the remaining period, thereby reducing power consumption.
In wireless communication in an infrastructure network, a station (which means a wireless communication apparatus and is hereinafter also referred to as “STA”) only receives beacons transmitted by an access point (hereinafter also referred to as “AP”). The station looks into a TIM (traffic indication map) contained in the received beacon, and determines if any data destined for it is buffered in the AP. If there is data destined for the station, the STA continues to feed power to the wireless transceiver, and transmits a PS-Poll packet to the AP.
When the AP receives the PS-Poll packet, it determines that the source STA (the STA that transmitted the PS-Poll packet) is ready to receive data (Awake) and transmits the buffered data in packet format to the STA. Upon receipt of the data packet, the STA immediately transmits to the AP an LACK packet that means completion of receipt.
The STA determines if more data is buffered in the AP in addition to the received packet by looking at a More Data flag included in the MAC header of the received packet. If the STA receives a packet with its More Data flag set to 1, it stays Awake. If the STA receives a packet with its More Data flag set to 0, it cuts power feeding to the wireless transceiver and shifts to a state where it cannot transmit and receive any data (Doze).
On the other hand, in wireless communication in an adhoc network, stations directly communicate with each other, and thus there is no AP which is always Awake. In such a case, at a destination STA to which a source STA is communicating, if power save mode is enabled (ON), the destination STA may be in the Awake or the Doze state, depending upon the timing of data transmission. If the destination STA is in the Doze state when data is transmitted, the destination STA cannot receive the data and packet loss may occur. Therefore, it is desirable that the source STA detects whether the PS mode of the destination STA is enabled or disabled.
For the method for detecting the PS mode of an STA, no specification is found in the IEEE802.11 standards. As a general method, however, an STA determines the PS mode of its partner STA by reference to a Power Management bit (PM bit) contained in the MAC header of a packet transmitted by the partner STA.
Therefore, the STA stores and updates the MAC address and PS mode for each STA by making use of beacons, etc. transmitted by other STAs participating in the adhoc network.
FIG. 1 illustrates a packet sequence where the power save mode of wireless communication apparatuses is enabled in an adhoc network. As shown in FIG. 1, if STA 2 transmits data to STA 3, for example, STA 2 transmits an ATIM packet to STA 3 within an ATIM Window in a beacon interval where all the STAs are Awake. This allows STA 3 to stay Awake during the beacon interval and STA 2 can transmit a data packet to STA 3.
If the ATIM Window is set to a value of 0 when the adhoc network is generated, there will be no ATIM Window period in the beacon interval, and thus power save mode cannot be enabled. Therefore, if the power save mode is enabled in the adhoc network, the ATIM Window must be set to a value of 1 or above when generating the network. It should be noted that when ATIM Window is used herein as a variable, the value indicates an ATIM Window period.
As described above, in order for one STA to participate and communicate in an adhoc network where STAs for which power save mode is enabled may exist, it must keep track of whether the power save mode of each of the STAs is enabled or disabled. For this purpose, the states of the PM bits contained in the packets of beacons, etc. transmitted by the STAs are detected. Then, the detected results are stored for each of the MAC addresses of the STAs, and are updated whenever necessary upon receipt of a packet.
However, because the method for detecting PS mode is not specified in the IEEE802.11 standard, there is no guarantee that the other STAs in communication perform the control as described above. Accordingly, when one STA has power save mode enabled and is in the Doze state, if another (partner) STA transmits a data packet to the STA, it may fail to receive the data packet. If the packet is an ARP packet which is issued when an IP address is assigned, a conflict of IP addresses may occur and adversely affect on the overall network.
The present invention has been made in view of the foregoing situation, and is characterized by providing technologies to prevent an STA from failing to receive packets transmitted by the other STAs on the network to which the STA belongs, even when PS mode of the STA is enabled.